package fr.dauphine.bookstore.test;

import org.hibernate.cfg.AnnotationConfiguration;
import org.hibernate.cfg.Configuration;
import org.hibernate.tool.hbm2ddl.SchemaExport;

/**
 * Creation du schema.
 */
public final class CreateDatabase {

	/**
	 * Constructeur prive.
	 */
	private CreateDatabase() {
	}

	/**
	 * Methode main.
	 *
	 * @param args
	 *            Arguments
	 */
	public static void main(final String[] args) {
		Configuration configuration = new AnnotationConfiguration().configure();
		SchemaExport export = new SchemaExport(configuration);
		export.setOutputFile("ddl/bookstore.ddl");
		export.create(true, true);
	}
}
